package com.zhufeng.base.api;

import com.alibaba.fastjson.JSONObject;
import com.zhufeng.base.fallback.UserFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @ClassName: FeginUserApi
 * @Description 对外提供api接口
 * @author 月夜烛峰
 * @date 2022/8/31 16:55
 */
@FeignClient(name = "zhufeng-web-user", fallbackFactory = UserFallbackFactory.class)
public interface ShowUserApi {

    /**
     * 根据id获取user信息
     * @param id
     * @return
     */
    @GetMapping("/fegin/{id}")
    JSONObject showUserById(@PathVariable("id") int id);

}
